package com.st.model;

import java.util.Date;

/**
 * LjwAclentryTId entity.
 * 
 * @author MyEclipse Persistence Tools
 */

public class LjwAclentryTId implements java.io.Serializable {

	// Fields

	private Integer roleId;
	private Integer permissionId;
	private Date creationDate;

	// Constructors

	/** default constructor */
	public LjwAclentryTId() {
	}

	/** full constructor */
	public LjwAclentryTId(Integer roleId, Integer permissionId,
			Date creationDate) {
		this.roleId = roleId;
		this.permissionId = permissionId;
		this.creationDate = creationDate;
	}

	// Property accessors

	public Integer getRoleId() {
		return this.roleId;
	}

	public void setRoleId(Integer roleId) {
		this.roleId = roleId;
	}

	public Integer getPermissionId() {
		return this.permissionId;
	}

	public void setPermissionId(Integer permissionId) {
		this.permissionId = permissionId;
	}

	public Date getCreationDate() {
		return this.creationDate;
	}

	public void setCreationDate(Date creationDate) {
		this.creationDate = creationDate;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof LjwAclentryTId))
			return false;
		LjwAclentryTId castOther = (LjwAclentryTId) other;

		return ((this.getRoleId() == castOther.getRoleId()) || (this
				.getRoleId() != null
				&& castOther.getRoleId() != null && this.getRoleId().equals(
				castOther.getRoleId())))
				&& ((this.getPermissionId() == castOther.getPermissionId()) || (this
						.getPermissionId() != null
						&& castOther.getPermissionId() != null && this
						.getPermissionId().equals(castOther.getPermissionId())))
				&& ((this.getCreationDate() == castOther.getCreationDate()) || (this
						.getCreationDate() != null
						&& castOther.getCreationDate() != null && this
						.getCreationDate().equals(castOther.getCreationDate())));
	}

	public int hashCode() {
		int result = 17;

		result = 37 * result
				+ (getRoleId() == null ? 0 : this.getRoleId().hashCode());
		result = 37
				* result
				+ (getPermissionId() == null ? 0 : this.getPermissionId()
						.hashCode());
		result = 37
				* result
				+ (getCreationDate() == null ? 0 : this.getCreationDate()
						.hashCode());
		return result;
	}

}